<%
  def varDomainName=tableNameUtil.lowerCaseFirst(tableDefine.id);
  def pkColumn=tableDefine.getPkColumn();
  def pkJavaType=tableNameUtil.getDataType(pkColumn?.columnType);
%>package ${config.basePackage}.service.${config.category};

import ${config.basePackage}.model.${config.category}.${tableDefine.id};
import com.github.miemiedev.mybatis.paginator.domain.PageBounds;
import com.github.miemiedev.mybatis.paginator.domain.PageList;
/**
 * ${tableDefine.cnname}service 接口
 *
 * @author ${config.author}
 * @date ${config.nowDate}
 */
public interface ${tableDefine.id}Service {

    /**
     * 增加
     *
     * @param ${varDomainName}
     * @return
     */
    int insert(${tableDefine.id} ${varDomainName});

    /**
     * 有选择的增加
     *
     * @param ${varDomainName}
     * @return
     */
    int insertSelective(${tableDefine.id} ${varDomainName});



<%
    if(pkColumn!=null){
%>

    /**
     * 根据主键删除${tableDefine.id}
     *
     * @param ${pkColumn.dataName}
     */
    int deleteByPrimaryKey(${pkJavaType} ${pkColumn.dataName});

    /**
     * 修改${tableDefine.id}
     *
     * @param ${varDomainName}
     */
    int updateByPrimaryKey(${tableDefine.id} ${varDomainName});

    /**
     * 有选择的修改${tableDefine.id}
     *
     * @param ${varDomainName}
     */
    int updateByPrimaryKeySelective(${tableDefine.id} ${varDomainName});



    /**
     * 根据主键查询${tableDefine.id}
     *
     * @param ${pkColumn.dataName}
     * @return
     */
    ${tableDefine.id} selectByPrimaryKey(${pkJavaType} ${pkColumn.dataName});
<%
    }
%>

    /**
     * 分页查询${tableDefine.id}
     *
     * @param ${varDomainName}
     */
    PageList<${tableDefine.id}> selectListBySelective(${tableDefine.id} ${varDomainName}, PageBounds pageBounds);

}
